![]() |
KCAddCallback |
||||
Header: | Keychain.h | Carbon status: | Under Evaluation | |
Registers your keychain event callback function.
OSStatus KCAddCallback ( KCCallbackUPP callbackProc, KCEventMask eventMask, void *userContext );
A Universal Procedure Pointer (UPP) to your keychain event callback function, described in KCCallbackProcPtr. You indicate the type of keychain events you want to receive by passing a bitmask of the desired events in the eventMask parameter. To create a UPP to your callback function, call the function NewKCCallbackUPP.
A bitmask indicating the keychain events that your application wishes to be notified of. See
A pointer to application-defined storage that will be passed to your callback function. Your application can use this to associate any particular call of KCAddCallback with any particular call of your keychain event callback function.
A result code. The result code errKCDuplicateCallback indicates that your callback function is already registered.
You can register your callback function by passing a UPP to it in the callbackProc parameter of the KCAddCallback function. Once you done so, the Keychain Manager calls the function InvokeKCCallbackUPP when the keychain event specified in the eventMask parameter occurs. In turn, InvokeKCCallbackUPP passes the keychain event, information about the event, and application-defined storage to your keychain event callback function.
Available beginning with Keychain 1.0.
© 2000 Apple Computer, Inc. (Last Updated 7/17/2000)